package com.lyf.scm.admin.domain.remote.allocationservice;

import com.lyf.scm.admin.api.dto.RoleAuthorityAreaDTO;
import com.rome.arch.core.clientobject.Response;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * 角色权限区域查询
 *
 * @author wangchlei
 * @date 2020/09/03
 */
@FeignClient(name = "scm-plan-service")
public interface RoleAuthorityAreaRemote {
    /**
     * 根据用户id查看用户的区域权限(直营渠道)
     *
     * @param userId
     * @return {@link Response<List<RoleAuthorityAreaDTO>>}
     **/
    @GetMapping("/api/v1/roleAuthorityArea/userId")
    Response<List<RoleAuthorityAreaDTO>> getRoleAuthorityAreaByUserId(@RequestParam("userId") Long userId);
}
